<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>

<div class="row" style="margin-top: 20px; padding-left: 20px;">
    <div class="form-group form-inline col-sm-6">
        <label class="">规则名称：</label>
        <input class="form-control" type="text" name="ruleName" value="${rule.ruleName}" placeholder="请输入规则名称">
    </div>
    <div class="form-group form-inline col-sm-6">
        <label class="">规则编号：</label>
        <input class="form-control" type="text" name="ruleCode" value="${rule.ruleCode}" placeholder="请输入积分规则编号">
    </div>
</div>
<div class="row" style="margin-top: 20px; padding-left: 20px;">
    <div class="form-group form-inline col-sm-6">
        <label class="">有效日期：</label>
        <input class="form-control" type="text" name="validDate" id="update_validDate" value="${rule.validDateStr}" placeholder="请选择有效日期">
    </div>
    <div class="form-group form-inline col-sm-6">
        <label class="">积分：</label>
        <input class="form-control" type="text" name="integral" value="${rule.integral}" placeholder="请输入规则对应积分" >
    </div>
</div>
<div class="row" style="margin-top: 20px; padding-left: 20px;">
    <div class="form-group form-inline col-sm-6">
        <label class="">执行频率：</label>
        <select class="form-control" name="ruleDetail" style="width:179px;">
            <option value="">---请选择---</option>
            <c:forEach items="${ruleDetails}" var="ruleDetail">
                <c:if test="${rule.ruleDetailId eq  ruleDetail.irdId}">
                	<option value="${ruleDetail.irdId}" selected="selected">${ruleDetail.ruleDetailName}</option>
                </c:if>
                <c:if test="${rule.ruleDetailId ne  ruleDetail.irdId}">
                	<option value="${ruleDetail.irdId}">${ruleDetail.ruleDetailName}</option>
                </c:if>
            </c:forEach>
        </select>
    </div>
    <div class="form-group form-inline col-sm-6">
        <label class="">是否启用：</label>
        <c:if test="${rule.disable eq 0}">
            <input name="disable" id="disable" type="checkbox" value="1">
        </c:if>
        <c:if test="${rule.disable eq 1}">
            <input name="disable" id="disable" type="checkbox" value="1" checked="checked">
        </c:if>
    </div>
</div>
<div class="row" style="margin-top: 20px; padding-left: 20px;">
    <div class="form-group form-inline col-sm-6">
        <label class="">创建日期：</label>
        <input name="created" id="created" type="text" value="${rule.created}" readonly="readonly">
    </div>
    <div class="form-group form-inline col-sm-6">
        <label class="">修改日期：</label>
        <input name="modified" id="modified" type="text" value="${rule.modified}" readonly="readonly">
    </div>
</div>
<div class="row" style="margin-top: 20px; padding-left: 20px;">
    <div class="form-group form-inline col-sm-6">
        <label class="">创建人：</label>
        <input class="form-control" type="text" name="creator" value="${rule.creator}" readonly="readonly" disabled="true">
        <input type="hidden" name="eId" value="${rule.eId}">
    </div>
    <div class="form-group form-inline col-sm-6">
        <label class="">修改人：</label>
        <input class="form-control" type="text" name="modifier" value="${rule.modifier}" readonly="readonly" disabled="true">
        <input type="hidden" name="modifierId" value="${rule.modifierId}">
    </div>
</div>
<input type="hidden" name="irId" value="${rule.irId}">